package com.gougang.interview;

/**
 * Created by 16978 on 2017/4/6.
 */
public enum Direction {
    West,
    East,
    North,
    South;


    public static Direction getType(int no) {
        for (Direction type : Direction.values()) {
            if (type.ordinal() == no) {
                return type;
            }
        }
        return null;
    }
}
